package com.example.classconnect.fragments;

import android.app.Fragment;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;

import com.example.classconnect.R;
import com.example.classconnect.User;

public class HomeFragment extends Fragment {
	public HomeFragment() {};
	private User currentUser;
	private TextView aboutMe;
	private TextView hob;
	private TextView club;
	private TextView HS;
	private TextView Living;
	
	@Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container,
            Bundle savedInstanceState) {
 
        View rootView = inflater.inflate(R.layout.fragment_home, container, false);
        currentUser = getArguments().getParcelable("CURRENTUSER");
        aboutMe = (TextView) rootView.findViewById(R.id.textView2);
        aboutMe.setText(currentUser.getDescription());
        hob = (TextView) rootView.findViewById(R.id.textView4);
        hob.setText(currentUser.getHobbies());
        club = (TextView) rootView.findViewById(R.id.textView6);
        club.setText(currentUser.getClubs());
        HS = (TextView) rootView.findViewById(R.id.textView8);
        HS.setText(currentUser.getHS());
        Living = (TextView) rootView.findViewById(R.id.textView10);
        Living.setText(currentUser.getLiving());
        
        return rootView;
    }
}
